package com.nacos.users.entity;

import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotEmpty;
import java.io.Serializable;

/**
 * 用户实体对象
 */
public class User implements Serializable {

    private String id;
    @NotEmpty(message = "名称不能为空")
    @Length(max = 12, message = "名称不能超过12位")
    private String name;

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }
}
